﻿
@{
    Layout = "~/Views/Shared/_LayoutIM.cshtml";
}

<!doctype html>
<html>
<head>
    <meta charset="utf-8">
    <meta name="viewport" content="width = device-width, initial-scale = 1.0, maximum-scale = 1.0, user-scalable = 0">
    <title>注册</title>
</head>

<body>
    <header class="header">
        <div class="header-return">
            <a href="javascript:history.go(-1);"></a>
        </div>

        <div class="logo">注册</div>
    </header>

    <section class="container">
        <div class="form-widget">
            <form  id="form">
                <div class="form-box">

                    <div class="form-group">
                        <label class="form-label">用户名</label>

                        <div class="form-control">
                            <input type="text" name="username" placeholder="请输入昵称">
                        </div>
                    </div>

                    <div class="form-group">
                        <label class="form-label">昵称</label>

                        <div class="form-control">
                            <input type="text" name="nickname" placeholder="请输入昵称">
                        </div>
                    </div>

                    <div class="form-group">
                        <label class="form-label">密码</label>

                        <div class="form-control">
                            <input type="password" name="password" placeholder="请输入密码">
                        </div>
                    </div>

                    @*<div class="form-group">
            <label class="form-label">确认密码</label>

            <div class="form-control">
                <input type="password" name="password" placeholder="请输入再次输入密码">
            </div>
        </div>*@

                    <div class="form-group">
                        <label class="form-label">手机号</label>

                        <div class="form-control">
                            <input type="tel" name="mobile" placeholder="请输入您的手机号">
                        </div>
                    </div>

                    <div class="form-group">
                        <label class="form-label">验证码</label>

                        <div class="form-control form-getcode">
                            <input placeholder="填写验证码">
                            <button>获取验证码</button>
                        </div>
                    </div>
                </div>

                <div class="form-submit">
                    <button type="button" id="Btn_Register" class="form-submit-btn">立即注册</button>
                </div>
            </form>
        </div>
    </section>
</body>
</html>
<script>
	$(function(){
		$('.language-box').click(function(){
			$('.choose-lang').fadeIn();
		});

		$('.choose-lang').click(function(){
			 $(this).fadeOut();
		});
    });

        $("#Btn_Register").click(function () {

            $.post("/Home/Register", $("#form").serialize(), function (data) {
                if (data.Status == 200)
                {
                    location.href = '/Home/ChatMain';
                }
                else
                {
                    alert(data.Message);
                }
            })
        })
</script>